package com.estagio.bean;  
  
import javax.faces.application.FacesMessage;
import javax.faces.context.FacesContext;

import org.primefaces.event.TabChangeEvent;
  
public class TabBean {  
  
    public void onTabChange(TabChangeEvent event) {  
        FacesMessage msg = new FacesMessage("Tab Changed", "Active Tab: " + event.getTab().getTitle()); 
        

  
        FacesContext.getCurrentInstance().addMessage(null, msg);  
    }  
}  
   